package cn.cs.client;

import cn.cs.config.CsConfiguration;
import cn.cs.fallback.AgentCapitalPoolTypeFallBack;
import cn.cs.fallback.AgentSettlementDetailedFallBack;
import cn.cs.pojo.CapitalPoolType;
import cn.cs.pojo.SettlementDetailed;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
import java.util.Map;

/**
 * Created by yuexl
 */
@FeignClient(name = "cs-agent-provider", configuration = CsConfiguration.class, fallback = AgentSettlementDetailedFallBack.class)
public interface AgentSettlementDetailedClient {


    @RequestMapping(value = "/getSettlementDetailedById", method = RequestMethod.POST)
    public Map<String, String> getSettlementDetailedById(@RequestParam("id") String  id) throws Exception;

    @RequestMapping(value = "/getSettlementDetailedListByMap", method = RequestMethod.POST)
    public List<SettlementDetailed> getSettlementDetailedListByMap(@RequestBody Map<String, Object> param) throws Exception;

    @RequestMapping(value = "/getSettlementDetailedCountByMap", method = RequestMethod.POST)
    public Integer getSettlementDetailedCountByMap(@RequestBody Map<String, Object> param) throws Exception;

    @RequestMapping(value = "/addSettlementDetailed", method = RequestMethod.POST)
    public Integer addSettlementDetailed(@RequestBody SettlementDetailed settlementDetailed) throws Exception;

    @RequestMapping(value = "/modifySettlementDetailed", method = RequestMethod.POST)
    public Integer modifySettlementDetailed(@RequestBody SettlementDetailed settlementDetailed) throws Exception;

    @RequestMapping(value = "/deleteSettlementDetailedById", method = RequestMethod.POST)
    public Integer deleteSettlementDetailedById(@RequestParam("id") String  id) throws Exception;

    @RequestMapping(value = "/updateSettlementDetailedState", method = RequestMethod.POST)
    public Integer updateSettlementDetailedState(@RequestParam("id")String id, @RequestParam("personId")String personId)throws Exception;

    @RequestMapping(value = "/insertRepairOrderList", method = RequestMethod.POST)
    public Integer insertRepairOrderList(List<Map<String, String>> list)throws Exception;

    @RequestMapping(value = "/getSetHisList", method = RequestMethod.POST)
    List<Map<String,Object>> getSetHisList(@RequestParam("id")String id);
    @RequestMapping(value = "/getSetInfoById", method = RequestMethod.POST)
    Map<String,Object> getSetInfoById(@RequestParam("id") String id);
    @RequestMapping(value = "/capitalInfoList", method = RequestMethod.POST)
    List<Map<String,Object>> capitalInfoList();
}

